//package com.xyy.saas.payment.job;
//
//import com.dangdang.ddframe.job.api.ShardingContext;
//import com.dangdang.ddframe.job.api.simple.SimpleJob;
//import com.pingan.openbank.api.sdk.client.ApiClient;
//import com.pingan.openbank.api.sdk.entity.FileRequest;
//import com.xyy.elasticjob.client.annotation.ElasticJobConf;
//import com.xyy.saas.payment.service.job.BalanceMonitorService;
//import com.xyy.saas.payment.util.ApolloUtil;
//import com.xyy.saas.payment.util.JSONUtils;
//import org.slf4j.Logger;
//import org.slf4j.LoggerFactory;
//import org.springframework.beans.factory.annotation.Autowired;
//
//import java.io.File;
//
///**
// * 10.6 还款计划回盘文件 下载
// */
//@ElasticJobConf(name = "xyy.elastic.job.manage.PinganLoanPullJob", cron = "0 0 10 * * ?")
//public class PinganLoanPullJob implements SimpleJob {
//    private static final Logger LOGGER = LoggerFactory.getLogger(PinganLoanPullJob.class);
//
//    // 实例化平安API对象
//    private static ApiClient apiClient = ApiClient.getInstance(ApolloUtil.getProperty("pingan.configPath"));
//
//    @Autowired
//    private BalanceMonitorService balanceMonitorService;
//
//    @Override
//    public void execute(ShardingContext shardingContext) {
////        LOGGER.info("PinganLoanPullJob#execute start. {}", JSONUtils.toJSON(shardingContext));
//        //封装请求对象
//        /*FileRequest fileRequest = new FileRequest();
//        //指定上传读取配置文件
//        //fileRequest.setConfigFilePath(config);
//        //设置需要上传文件内容
//        fileRequest.setFile(new File("D:\\平安对公开放银行SDK使用手册v1.0.12.docx"));
//        //设置文件上传服务器文件路径
//        fileRequest.setFilePathName("/ejzb/test.txt");
//        //调用接口请求
//        String fileNo = apiClient.fileUpload(fileRequest);*/
//
////        String config = "config/config-4294-test.properties";
////        ApiClient fileClient = ApiClient.getInstance(config);
////
////        //封装请求对象
////        FileRequest fileRequest = new FileRequest();
////        //指定下载读取配置文件
////        //fileRequest.setConfigFilePath(config);
////        //设置文档编号
////        fileRequest.setFileNo("UDMP-85f66b0b5c491ae501d26186b15facb16a02e8d4ad-a36218c7-20221013145337-00000001");
////        //设置文件下载本地文件路径
////        fileRequest.setFilePathName("D:\\New平安对公开放银行SDK使用手册v1.0.12.docx");
////        //调用接口请求
////        fileClient.fileDownLoad(fileRequest);
////
////        LOGGER.info("PinganLoanPullJob#execute end.");
//    }
//}
